﻿using HelperFromTheSkeleton.ConsoleApp;
using HelperFromTheSkeleton.Convert;
using HelperFromTheSkeleton.HttpHelper;
using System.Collections.Concurrent;
using System.Linq.Expressions;
using System.Text;


var data = DateTime.UtcNow-new DateTime(1970,1,1);
var dataString = DateTime.Now.ToString();
var dataTick = data.Ticks;
ConcurrentDictionary<string, ulong> _inventoryDic = new ConcurrentDictionary<string, ulong>();
ulong value = 1;
_inventoryDic.TryAdd("1", value);
_inventoryDic.TryUpdate("1", 1, 2);

GetPatinfoInfoRequestModel model = new ()
{
    itemNo = "1",
    itemType = "2"
};
GetPatinfoInfoRequestModel model2 = new ()
{
    itemNo = "1",
    itemType = "1"
};
GetPatinfoInfoRequestModel model3 = new ()
{
    itemNo = "2",
    itemType = "2"
};
List<GetPatinfoInfoRequestModel> models = new () { model, model2, model3 };
Expression<Func<GetPatinfoInfoRequestModel, bool>> expression = m => m.itemNo == "1";
Expression<Func<GetPatinfoInfoRequestModel, bool>> expression2 = m => m.itemType == "1";
expression = expression.And(expression2);


//Http http = new Http();
//HttpRequestMessage httpRequestMessage = new HttpRequestMessage();
//httpRequestMessage.Method = HttpMethod.Post;
//httpRequestMessage.RequestUri = new Uri("http://172.30.9.242:8050/api/HISInteraction/GetPatinfoInfo");
////httpRequestMessage.Headers.Add("Accept", "application/json");


//var modelJson = model.ToJson();
//var jsonByte = Encoding.UTF8.GetBytes(modelJson);
//var memoryStream = new MemoryStream(jsonByte);
//httpRequestMessage.Content = new StringContent(modelJson);
//httpRequestMessage.Content.Headers.ContentType = new System.Net.Http.Headers.MediaTypeHeaderValue("application/json");
//var a = http.Send(httpRequestMessage);
Console.WriteLine("Hello, World!");
